package com.wuwei.tms.pojo;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;

import com.wuwei.tms.config.BaseDateConverter;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * <p>
 *
 * </p>
 *
 * @author wuwei
 * @since 2024-01-03
 */
@TableName("t_history")
@Data
@ApiModel(value = "THistory对象", description = "")
public class History implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    @ExcelIgnore
    private Long id;

    @ColumnWidth(20)
    @ExcelProperty(value = {"借用时间"}, converter = BaseDateConverter.LocalDateTimeConverter.class)
    private LocalDateTime borrowTime;

    @ColumnWidth(20)
    @ExcelProperty(value = {"归还时间"}, converter = BaseDateConverter.LocalDateTimeConverter.class)
    private LocalDateTime returnTime;

    @ExcelProperty("飞机注册号")
    private String airplaneId;

    @ExcelIgnore
    @ApiModelProperty("t_user表的empno")
    private Long borrowById;

    @ExcelIgnore
    @ApiModelProperty("t_user表的empno")
    private Long returnById;

    @ExcelProperty("借用数量")
    private Integer borrowCount;

    @ExcelProperty("归还数量")
    private Integer returnCount;

    @ColumnWidth(13)
    @ExcelProperty("工具编号")
    private Long barcode;

    @ExcelIgnore
    @ApiModelProperty("t_user表的empno")
    private Long operator;

    @ColumnWidth(20)
    @ExcelProperty("工具名称")
    private String toolName;//t_tool表的工具名称

    @ExcelProperty("操作者")
    @ApiModelProperty("t_user表的empno")
    private String operatorName;


}
